/* Jest HTML Reporter 自定义样式 */

/* 整体页面样式 */
body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    margin: 0;
    padding: 20px;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    background: white;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
    overflow: hidden;
}

/* 标题区域 */
.header {
    background: linear-gradient(45deg, #2196F3, #21CBF3);
    color: white;
    padding: 30px;
    text-align: center;
}

.header h1 {
    margin: 0;
    font-size: 2.5em;
    font-weight: 300;
}

.header p {
    margin: 10px 0 0 0;
    opacity: 0.9;
    font-size: 1.1em;
}

/* 统计信息卡片 */
.stats-container {
    display: flex;
    justify-content: space-around;
    padding: 30px;
    background: #f8f9fa;
    border-bottom: 1px solid #e9ecef;
}

.stat-card {
    text-align: center;
    padding: 20px;
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    min-width: 120px;
}

.stat-number {
    font-size: 2.5em;
    font-weight: bold;
    color: #28a745;
}

.stat-label {
    color: #6c757d;
    font-size: 0.9em;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* 测试套件样式 */
.suite {
    margin: 20px;
    border: 1px solid #e9ecef;
    border-radius: 8px;
    overflow: hidden;
}

.suite-header {
    background: #495057;
    color: white;
    padding: 15px 20px;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.3s;
}

.suite-header:hover {
    background: #343a40;
}

.suite-header.passed {
    background: #28a745;
}

.suite-header.failed {
    background: #dc3545;
}

/* 测试用例样式 */
.test {
    padding: 12px 20px;
    border-bottom: 1px solid #f8f9fa;
    transition: background-color 0.2s;
}

.test:hover {
    background: #f8f9fa;
}

.test.passed {
    border-left: 4px solid #28a745;
}

.test.failed {
    border-left: 4px solid #dc3545;
    background: #fff5f5;
}

.test-name {
    font-weight: 500;
    color: #495057;
}

.test-duration {
    float: right;
    color: #6c757d;
    font-size: 0.9em;
}

/* 错误信息样式 */
.error-message {
    background: #f8d7da;
    border: 1px solid #f5c6cb;
    border-radius: 4px;
    padding: 15px;
    margin: 10px 0;
    font-family: 'Courier New', monospace;
    font-size: 0.9em;
    color: #721c24;
    white-space: pre-wrap;
}

/* 覆盖率信息 */
.coverage-summary {
    background: #e3f2fd;
    border: 1px solid #bbdefb;
    border-radius: 8px;
    padding: 20px;
    margin: 20px;
}

.coverage-title {
    font-weight: 600;
    color: #1976d2;
    margin-bottom: 15px;
}

/* 进度条样式 */
.progress-bar {
    background: #e9ecef;
    border-radius: 10px;
    overflow: hidden;
    height: 20px;
    margin: 5px 0;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(45deg, #28a745, #20c997);
    transition: width 0.5s ease;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .stats-container {
        flex-direction: column;
        gap: 15px;
    }
    
    .header h1 {
        font-size: 2em;
    }
    
    .container {
        margin: 10px;
        border-radius: 8px;
    }
}

/* 暗色主题 */
@media (prefers-color-scheme: dark) {
    body {
        background: linear-gradient(135deg, #2c3e50 0%, #34495e 100%);
    }
    
    .container {
        background: #2c3e50;
        color: #ecf0f1;
    }
    
    .stats-container {
        background: #34495e;
    }
    
    .stat-card {
        background: #2c3e50;
        color: #ecf0f1;
    }
}